#include<stdio.h>

int main()
{
	int n,x,i,j,flag;
	int a[105];
	while (scanf("%d%d",&n,&x)==2)
	{
		if (n==0)
		{
			printf("End Of Input\n");
			break;
		}
		if (n>100||n<0)
		{
			printf("Input Error\n");
			continue;
		}
		for (i=1;i<=n;i++)
			scanf("%d",&a[i]);
		if (n==1)
			if (a[1]==x)
			{
				printf("%d\n",n);
				continue;
			}
			else
			{
				printf("Input Error\n");
				continue;
			}
		for (i=1;i<=n-1;i++)
		{
			flag=1;
			for (j=i+1;j<=n;j++)
				if (a[i]==a[j])
				{
					printf("Input Error\n");
					flag=0;
					break;
				}
			if (flag==0)
				break;
		}
		if (flag==0)
			continue;
		for (i=1;i<=n;i++)
		{
			flag=1;
			if (a[i]==x)
			{
				flag=0;
				printf("%d\n",i);
			} 
			if (flag==0)
				break;
		}
		if (flag==1)
			printf("Input Error\n");
	}
	return 0;
}
